package org.sdp.pearproject.dto.convert;

import org.sdp.pearproject.dao.domain.*;
import org.sdp.pearproject.dto.request.*;
import java.util.Date;

/**
 * @ClassName: TaskToTagAddRequestConvert
 * @Description:
 * @Author: SDP
 * @Date: 2022-07-18
 * @Version: 1.0
 * Table: pear_task_to_tag
 * Comment:
 * 任务标签映射表
 */
public class TaskToTagAddRequestConvert extends BaseConvert {
    public static TaskToTagWithBLOBs convert(TaskToTagAddRequest request) throws Exception {
        TaskToTagWithBLOBs daoRequest = new TaskToTagWithBLOBs();
        copyProperties(request, daoRequest);

        daoRequest.setCode(daoRequest.getCode() == null ? null : daoRequest.getCode().trim());
        daoRequest.setTaskCode(daoRequest.getTaskCode() == null ? null : daoRequest.getTaskCode().trim());
        daoRequest.setTagCode(daoRequest.getTagCode() == null ? null : daoRequest.getTagCode().trim());

        return daoRequest;
    }
}
